package com.chixing.day02_switch_case;

import sun.plugin.javascript.navig.Array;

import java.util.ArrayList;
import java.util.Arrays;

public class ArrayDemo {
    /**
     * 引用数据类型默认为null 测试-1.0
     * @param args
     */
    public static void main(String[] args) {
        float[] arr3={9.9f,4.5f,3.6f,12};
        System.out.println(arr3[0]);

        int[][] a=new int[2][5];
        int[][] a1={{1,2,3},{4,5,6}};
        System.out.println(a1[0].length);
        System.out.println("------------");
        //数组的工具类 Arrays
        float[] floats = Arrays.copyOfRange(arr3, 0,arr3.length);
        Arrays.sort(arr3);
//        for (int i = 0; i < arr3.length; i++) {
//            System.out.println(arr3[i]);
//        }
        int i = Arrays.binarySearch(arr3,4.5f);
        System.out.println(i);
    }


}
